]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
viewSelector: Don't unfocus other modals on reset
authorAndrea Azzarone <andrea.azzarone@canonical.com>
Thu, 4 Oct 2018 13:05:44 +0000 (14:05 +0100)
committerFlorian Müllner <florian.muellner@gmail.com>
Thu, 4 Oct 2018 16:40:46 +0000 (16:40 +0000)
Don't drop the key focus on Clutter's side if anything but the overview has
pushed a modal (e.g. system modals when activated using the overview).

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/issues/618
js/ui/viewSelector.js

index c650886d249f7f7260de143941ab01f699789fdd..6a235eccde0c7961f3c3ae027b58693815ee7f51 100644 (file)
@@ -460,7 +460,11 @@ var ViewSelector = new Lang.Class({
     },
 
     reset() {
-        global.stage.set_key_focus(null);
+        // Don't drop the key focus on Clutter's side if anything but the
+        // overview has pushed a modal (e.g. system modals when activated using
+        // the overview).
+        if (Main.modalCount <= 1)
+            global.stage.set_key_focus(null);
 
         this._entry.text = '';